Skip to content

Update bigsuds.py#11

Open
avictor0826 wants to merge 1 commit intoF5Networks:masterfrom
avictor0826:patch-1
Open

Update bigsuds.py#11
avictor0826 wants to merge 1 commit intoF5Networks:masterfrom
avictor0826:patch-1

Conversation

@avictor0826
Copy link

Fixed issue with regex.search() method in python 3

Error stack as given below
b = bigsuds.BIGIP(hostname = host, username=user, password=password, debug=True)
File "/users/ok8xe4d/djangoenv/lib/python3.6/site-packages/bigsuds.py", line 145, in init
self._instantiate_namespaces()
File "/users/ok8xe4d/djangoenv/lib/python3.6/site-packages/bigsuds.py", line 205, in _instantiate_namespaces
self._timeout, self._port)
File "/users/ok8xe4d/djangoenv/lib/python3.6/site-packages/bigsuds.py", line 329, in get_wsdls
result = regex.search(line)
TypeError: cannot use a string pattern on a bytes-like object

Reason: regex.search() expects a string whereas the readLine() returns a byte

Fixed issue with regex.search() method in python 3

Error stack as given below
    b = bigsuds.BIGIP(hostname = host, username=user, password=password, debug=True)
  File "/users/ok8xe4d/djangoenv/lib/python3.6/site-packages/bigsuds.py", line 145, in __init__
    self._instantiate_namespaces()
  File "/users/ok8xe4d/djangoenv/lib/python3.6/site-packages/bigsuds.py", line 205, in _instantiate_namespaces
    self._timeout, self._port)
  File "/users/ok8xe4d/djangoenv/lib/python3.6/site-packages/bigsuds.py", line 329, in get_wsdls
    result = regex.search(line)
TypeError: cannot use a string pattern on a bytes-like object


Reason: regex.search() expects a string whereas the readLine() returns a byte
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant